package com.aia.prm.web.ria.app.ui.group;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.aia.prm.domain.VOGroup;
import com.aia.prm.domain.VOPlan;
import com.vaadin.data.util.BeanItemContainer;

@SuppressWarnings("serial")
public class GroupContainer extends BeanItemContainer<VOGroup> implements Serializable {
	public static final Object[] NATURAL_COL_ORDER = new Object[] { "PL_ID", "GP_PK", "GP_NAME", "GP_TYPE1", "GP_TYPE2", "GP_TYPE3",
			"GP_MAINCODE", "GP_EXTCODE1", "GP_EXTCODE2", "GP_EXTCODE3" };

	public static final String[] COL_HEADERS_SHOW = new String[] { "产品ID", "数字", "短名", "分类1", "分类2", "分类3", "主险代码", "附加1Code", "附加2Code",
			"附加3Code" };

	public static final Object[] NATURAL_COL_ORDER_FORM = new Object[] { "PL_ID", "GP_PK", "GP_NAME", "GP_TYPE1", "GP_TYPE2", "GP_TYPE3",
			"GP_MAINCODE", "GP_EXTCODE1", "GP_EXTCODE2", "GP_EXTCODE3", "GP_EXTCODE4", "GP_EXTCODE5", "GP_EXTCODE6", "GP_EXTCODE7",
			"GP_EXTCODE8", "GP_AGEMIN", "GP_AGEMAX" };

	public static final Map<String, String> FIELD_NAME_MAP = new HashMap<String, String>();

	static {
		FIELD_NAME_MAP.put("PL_ID", "产品ID");
		FIELD_NAME_MAP.put("GP_PK", "数字");
		FIELD_NAME_MAP.put("GP_NAME", "短名");
		FIELD_NAME_MAP.put("GP_TYPE1", "分类1");
		FIELD_NAME_MAP.put("GP_TYPE2", "分类2");
		FIELD_NAME_MAP.put("GP_TYPE3", "分类3");
		FIELD_NAME_MAP.put("GP_MAINCODE", "主险代码");
		FIELD_NAME_MAP.put("GP_EXTCODE1", "附加1Code");
		FIELD_NAME_MAP.put("GP_EXTCODE2", "附加2Code");
		FIELD_NAME_MAP.put("GP_EXTCODE3", "附加3Code");
		FIELD_NAME_MAP.put("GP_EXTCODE4", "附加4Code");
		FIELD_NAME_MAP.put("GP_EXTCODE5", "附加5Code");
		FIELD_NAME_MAP.put("GP_EXTCODE6", "附加6Code");
		FIELD_NAME_MAP.put("GP_EXTCODE7", "附加7Code");
		FIELD_NAME_MAP.put("GP_EXTCODE8", "附加8Code");
		FIELD_NAME_MAP.put("GP_AGEMIN", "投保年龄最小值");
		FIELD_NAME_MAP.put("GP_AGEMAX", "投保年龄最大值");
	}

	public static final List<String> PLAN_TYPE_LIST = new ArrayList<String>();
	static {
		PLAN_TYPE_LIST.add("合同");
		PLAN_TYPE_LIST.add("保险金");
	}

	public GroupContainer() throws InstantiationException, IllegalAccessException {
		super(VOGroup.class);
	}
}